<!doctype html>
<html lang="en" xmlns="http://www.w3.org/1999/xhtml"
	xmlns:fb="http://www.facebook.com/2008/fbml">
<head>
	<meta name="layout" content="main">
	<r:require module="export"/>
</head>
<body>
	<div class="page-header">
		<h1>
			<g:message code="notification.title" />
		</h1>
	</div>
		
	<g:if test="${notificationsList.size()>0}">		
		<div class="separator"></div>
					
		<div class="row">
			<table class="table table-striped span12">
				<thead>
					<tr>																							
						<th>${message(code: 'notification.date')} </th>
						<th>${message(code: 'notification.description')} </th>
						<th>${message(code: 'notification.see')} </th>												
					</tr>
				</thead>
				<tbody>
					<g:each in="${notificationsList}" status="i" var="notification">
						<tr>														
							<td><g:formatDate format="dd-MM-yyyy"  date="${notification.dateCreated}" /></td>
							<td>${fieldValue(bean: notification, field: "description")}</td>
							<td>
								<g:if test="${ notification.associatedUrl?.length() > 0}">
									<a href="${fieldValue(bean: notification, field: "associatedUrl")}">
										<img alt="" src="${resource(dir:'images',file:'notifications_m.png')}"/>
									</a>
								</g:if>									
							</td>							
						</tr>
					</g:each>
				</tbody>
			</table>
			
		</div>
		<div class="pagination">
			<g:paginate total="${total}"/>	
		</div>	
	</g:if>
	<g:else>
		<div id="noNotifications" class="alert alert-warning">  
		  <a class="close" data-dismiss="alert">×</a>  
		  <div class="message"><g:message code="notifications.noElements" /></div>  
		</div>
	</g:else>
	
	<script type="text/javascript">

    </script>	
    
	</body>
</html>
